package avicit.bdp.dms.das.dto;

import avicit.bdp.common.base.BaseDTO;
import avicit.platform6.core.annotation.log.FieldRemark;
import avicit.platform6.core.annotation.log.Id;
import avicit.platform6.core.annotation.log.LogField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.lang3.StringUtils;

import javax.persistence.Column;
import javax.persistence.Table;
import javax.persistence.Transient;


/**
 * 业务对象表实体
 * 
 */
@ApiModel(value = "DasBusinessDTO", description = "业务对象表")
@Table(name = "bdp_das_business")
public class BusinessDTO extends BaseDTO {

	/**
	* id
	*
	*/
	@LogField
	@ApiModelProperty(value = "id")
	@FieldRemark(column = "id", field = "id", name = "id")
	@Column(name = "id")
	@Id
	@javax.persistence.Id
	private String id;

	/**
	 * 名称
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "名称")
	@FieldRemark(column = "name", field = "name", name = "名称")
	@Column(name = "name")
    private String name;
	/**
	 * 0-业务实体 1-业务过程
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "0-业务实体 1-业务过程")
	@FieldRemark(column = "type", field = "type", name = "0-业务实体 1-业务过程")
	@Column(name = "type")
    private Integer type;
	/**
	 * 0-草稿 1-启用 2-停用
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "0-草稿 1-启用 2-停用")
	@FieldRemark(column = "status", field = "status", name = "0-草稿 1-启用 2-停用")
	@Column(name = "status")
    private Integer status;
	/**
	 * 主题id
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "主题id")
	@FieldRemark(column = "category_id", field = "categoryId", name = "主题id")
	@Column(name = "category_id")
    private String categoryId;
	/**
	 * 关联维度id
	 * 
	 */
	/*@LogField
	@ApiModelProperty(value = "关联维度id")
	@FieldRemark(column = "dimension_id", field = "dimensionId", name = "关联维度id")
	@Column(name = "dimension_id")
    private String dimensionId;*/
	/**
	 * 位置x
	 *
	 */
	@LogField
	@ApiModelProperty(value = "位置x")
	@FieldRemark(column = "business_x", field = "businessX", name = "关联维度id")
	@Column(name = "business_x")
	private String businessX;
	/**
	 * 位置y
	 *
	 */
	@LogField
	@ApiModelProperty(value = "位置y")
	@FieldRemark(column = "business_y", field = "businessY", name = "关联维度id")
	@Column(name = "business_y")
	private String businessY;
	/**
	 * 宽度
	 *
	 */
	@LogField
	@ApiModelProperty(value = "宽度")
	@FieldRemark(column = "business_width", field = "businessWidth", name = "关联维度id")
	@Column(name = "business_width")
	private String businessWidth;
	/**
	 * 高度
	 *
	 */
	@LogField
	@ApiModelProperty(value = "高度")
	@FieldRemark(column = "business_height", field = "businessHeight", name = "关联维度id")
	@Column(name = "business_height")
	private String businessHeight;
	/**
	 * 样式
	 *
	 */
	@LogField
	@ApiModelProperty(value = "样式")
	@FieldRemark(column = "business_style", field = "businessStyle", name = "关联维度id")
	@Column(name = "business_style")
	private String businessStyle;
	/**
	 * 备注
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "备注")
	@FieldRemark(column = "remark", field = "remark", name = "备注")
	@Column(name = "remark")
    private String remark;
	/**
	 * 排序
	 * 
	 */
	@LogField
	@ApiModelProperty(value = "排序")
	@FieldRemark(column = "order_by", field = "orderBy", name = "排序")
	@Column(name = "order_by")
    private Integer orderBy;

	@ApiModelProperty(value = "状态")
	@Transient
	private String statusString;

	@ApiModelProperty(value = "主题名称")
	@Transient
	private String categoryName;

	@ApiModelProperty(value = "ID集合用于批量操作")
	@Transient
	private String ids;

	/*@ApiModelProperty(value = "关联维度名称")
	@Transient
	private String dimensionName;*/

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getType() {
		return type;
	}

	public void setType(Integer type) {
		this.type = type;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public String getCategoryId() {
		return categoryId;
	}

	public void setCategoryId(String categoryId) {
		this.categoryId = categoryId;
	}

	/*public String getDimensionId() {
		return dimensionId;
	}

	public void setDimensionId(String dimensionId) {
		this.dimensionId = dimensionId;
	}*/

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Integer getOrderBy() {
		return orderBy;
	}

	public void setOrderBy(Integer orderBy) {
		this.orderBy = orderBy;
	}

	public String getStatusString() {
		return statusString;
	}

	public void setStatusString(String statusString) {
		this.statusString = statusString;
	}

	public String getCategoryName() {
		return categoryName;
	}

	public void setCategoryName(String categoryName) {
		this.categoryName = categoryName;
	}

	/*public String getDimensionName() {
		return dimensionName;
	}

	public void setDimensionName(String dimensionName) {
		this.dimensionName = dimensionName;
	}*/

	public String getBusinessX() {
		return businessX;
	}

	public void setBusinessX(String businessX) {
		this.businessX = businessX;
	}

	public String getBusinessY() {
		return businessY;
	}

	public void setBusinessY(String businessY) {
		this.businessY = businessY;
	}

	public String getBusinessWidth() {
		return businessWidth;
	}

	public void setBusinessWidth(String businessWidth) {
		this.businessWidth = businessWidth;
	}

	public String getBusinessHeight() {
		return businessHeight;
	}

	public void setBusinessHeight(String businessHeight) {
		this.businessHeight = businessHeight;
	}

	public String getBusinessStyle() {
		return businessStyle;
	}

	public void setBusinessStyle(String businessStyle) {
		this.businessStyle = businessStyle;
	}

	public String getIds() {
		return ids;
	}

	public void setIds(String ids) {
		this.ids = ids;
	}

	@Override
	public String getLogFormName() {
		if (StringUtils.isEmpty(super.logFormName)) {
			return "业务对象";
		} else {
			return super.logFormName;
		}
	}

	@Override
	public String getLogTitle() {
		if (StringUtils.isEmpty(super.logTitle)) {
			return "对象";
		} else {
			return super.logTitle;
		}
	}

}

